Optimal. Leaf size=183 \[ \frac {2 (a+b \text {ArcTan}(c+d x))^2 \tanh ^{-1}\left (1-\frac {2}{1+i (c+d x)}\right )}{d e}-\frac {i b (a+b \text {ArcTan}(c+d x)) \text {PolyLog}\left (2,1-\frac {2}{1+i (c+d x)}\right )}{d e}+\frac {i b (a+b \text {ArcTan}(c+d x)) \text {PolyLog}\left (2,-1+\frac {2}{1+i (c+d x)}\right )}{d e}-\frac {b^2 \text {PolyLog}\left (3,1-\frac {2}{1+i (c+d x)}\right )}{2 d e}+\frac {b^2 \text {PolyLog}\left (3,-1+\frac {2}{1+i (c+d x)}\right )}{2 d e} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.22, antiderivative size = 183, normalized size of antiderivative = 1.00, number of steps
used = 8, number of rules used = 7, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.304, Rules used = {5151, 12, 4942,
5108, 5004, 5114, 6745} \begin {gather*} -\frac {i b \text {Li}_2\left (1-\frac {2}{i (c+d x)+1}\right ) (a+b \text {ArcTan}(c+d x))}{d e}+\frac {i b \text {Li}_2\left (\frac {2}{i (c+d x)+1}-1\right ) (a+b \text {ArcTan}(c+d x))}{d e}+\frac {2 \tanh ^{-1}\left (1-\frac {2}{1+i (c+d x)}\right ) (a+b \text {ArcTan}(c+d x))^2}{d e}-\frac {b^2 \text {Li}_3\left (1-\frac {2}{i (c+d x)+1}\right )}{2 d e}+\frac {b^2 \text {Li}_3\left (\frac {2}{i (c+d x)+1}-1\right )}{2 d e} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 4942
Rule 5004
Rule 5108
Rule 5114
Rule 5151
Rule 6745
Rubi steps
\begin {align*} \int \frac {\left (a+b \tan ^{-1}(c+d x)\right )^2}{c e+d e x} \, dx &=\frac {\text {Subst}\left (\int \frac {\left (a+b \tan ^{-1}(x)\right )^2}{e x} \, dx,x,c+d x\right )}{d}\\ &=\frac {\text {Subst}\left (\int \frac {\left (a+b \tan ^{-1}(x)\right )^2}{x} \, dx,x,c+d x\right )}{d e}\\ &=\frac {2 \left (a+b \tan ^{-1}(c+d x)\right )^2 \tanh ^{-1}\left (1-\frac {2}{1+i (c+d x)}\right )}{d e}-\frac {(4 b) \text {Subst}\left (\int \frac {\left (a+b \tan ^{-1}(x)\right ) \tanh ^{-1}\left (1-\frac {2}{1+i x}\right )}{1+x^2} \, dx,x,c+d x\right )}{d e}\\ &=\frac {2 \left (a+b \tan ^{-1}(c+d x)\right )^2 \tanh ^{-1}\left (1-\frac {2}{1+i (c+d x)}\right )}{d e}-\frac {(2 b) \text {Subst}\left (\int \frac {\left (a+b \tan ^{-1}(x)\right ) \log \left (2-\frac {2}{1+i x}\right )}{1+x^2} \, dx,x,c+d x\right )}{d e}+\frac {(2 b) \text {Subst}\left (\int \frac {\left (a+b \tan ^{-1}(x)\right ) \log \left (\frac {2}{1+i x}\right )}{1+x^2} \, dx,x,c+d x\right )}{d e}\\ &=\frac {2 \left (a+b \tan ^{-1}(c+d x)\right )^2 \tanh ^{-1}\left (1-\frac {2}{1+i (c+d x)}\right )}{d e}-\frac {i b \left (a+b \tan ^{-1}(c+d x)\right ) \text {Li}_2\left (1-\frac {2}{1+i (c+d x)}\right )}{d e}+\frac {i b \left (a+b \tan ^{-1}(c+d x)\right ) \text {Li}_2\left (-1+\frac {2}{1+i (c+d x)}\right )}{d e}+\frac {\left (i b^2\right ) \text {Subst}\left (\int \frac {\text {Li}_2\left (1-\frac {2}{1+i x}\right )}{1+x^2} \, dx,x,c+d x\right )}{d e}-\frac {\left (i b^2\right ) \text {Subst}\left (\int \frac {\text {Li}_2\left (-1+\frac {2}{1+i x}\right )}{1+x^2} \, dx,x,c+d x\right )}{d e}\\ &=\frac {2 \left (a+b \tan ^{-1}(c+d x)\right )^2 \tanh ^{-1}\left (1-\frac {2}{1+i (c+d x)}\right )}{d e}-\frac {i b \left (a+b \tan ^{-1}(c+d x)\right ) \text {Li}_2\left (1-\frac {2}{1+i (c+d x)}\right )}{d e}+\frac {i b \left (a+b \tan ^{-1}(c+d x)\right ) \text {Li}_2\left (-1+\frac {2}{1+i (c+d x)}\right )}{d e}-\frac {b^2 \text {Li}_3\left (1-\frac {2}{1+i (c+d x)}\right )}{2 d e}+\frac {b^2 \text {Li}_3\left (-1+\frac {2}{1+i (c+d x)}\right )}{2 d e}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.05, size = 170, normalized size = 0.93 \begin {gather*} \frac {4 (a+b \text {ArcTan}(c+d x))^2 \tanh ^{-1}\left (\frac {i+c+d x}{-i+c+d x}\right )+2 i b (a+b \text {ArcTan}(c+d x)) \text {PolyLog}\left (2,-\frac {i+c+d x}{-i+c+d x}\right )-2 i b (a+b \text {ArcTan}(c+d x)) \text {PolyLog}\left (2,\frac {i+c+d x}{-i+c+d x}\right )+b^2 \text {PolyLog}\left (3,-\frac {i+c+d x}{-i+c+d x}\right )-b^2 \text {PolyLog}\left (3,\frac {i+c+d x}{-i+c+d x}\right )}{2 d e} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [C] Result contains higher order function than in optimal. Order 9 vs. order
4.
time = 1.71, size = 1362, normalized size = 7.44
method | result | size |
derivativedivides | \(\text {Expression too large to display}\) | \(1362\) |
default | \(\text {Expression too large to display}\) | \(1362\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \frac {\int \frac {a^{2}}{c + d x}\, dx + \int \frac {b^{2} \operatorname {atan}^{2}{\left (c + d x \right )}}{c + d x}\, dx + \int \frac {2 a b \operatorname {atan}{\left (c + d x \right )}}{c + d x}\, dx}{e} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {{\left (a+b\,\mathrm {atan}\left (c+d\,x\right )\right )}^2}{c\,e+d\,e\,x} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________